POV-Ray : Newsgroups : povray.general : IES file format : Re: IES file format Server Time
2 Nov 2024 15:24:52 EDT (-0400)
  Re: IES file format  
From: Gianluca Massaccesi
Date: 30 Jan 2004 08:57:51
Message: <401a62df@news.povray.org>
The sintax is clear. The problem is now how to produce a png file from an
ies file.
Attached there are 2 example. One very simple (prova_06.txt) and another of
the size I have to use. It represent a light source of 45x99 values for each
angle. Till now I simulated it with 45x99 spotlights. But you can immagine
that the performances are not good enough.
Your way maybe is faster but it is difficult to traslate such files in png
format (I have not the specifications of the format neither).

Can you suggest something easier?

Thanks.

Gianluca Massaccesi

"Peter Popov" <pet### [at] vipbg> ha scritto nel messaggio
news:cn4i10dpa0m0j20fsblmo9938ljsssvbe4@4ax.com...
> On Thu, 29 Jan 2004 14:33:44 +0100, "Gianluca Massaccesi"
> <gia### [at] tinit> wrote:
>
> >Thank you. This could be an idea. IES format gives luminosity in function
of
> >horizontal and vertical angle.
>
> So it's a mercator projection then? This should make things more
> simple. Just convert it to something POV can read. Probably the best
> format is 16-bit grayscale PNG with 16-bit alpha. Make the gray
> channel 100% white and store the luminosity as transparency in the
> alpha channel. I.e. the more luminance, the more transparent the image
> map will be and the more light will shine through, which is what we
> want.
>
> In terms of POV code it looks quite simple once you have the PNG file:
>
> #macro IES_Light_Source (Location, Color, Transparency_Map_File) {
>    union {
>       light_source { 0 color Color }
>       sphere {
>          0, 0.001
>          pigment {
>             image_map {
>                png Transparency_Map_File
>                map_type 1
>             }
>          }
>          no_image
>       }
>       translate Location
>    }
> }
>
> Then use the macro like this:
>
> IES_Light_Source ( <10,100,-20>, rgb 100, "foo_file.png" )
>
> You can also use a plain simple 16-bit PNG without the alpha channel,
> then use image_pattern to create a transparency map, but that's just
> nitpicking :)
>
> There might be some errors in the code since I am typing it directly
> in the newsreader, but you get the idea.
>
>
> Peter Popov ICQ : 15002700
> Personal e-mail : pet### [at] vipbg
> TAG      e-mail : pet### [at] tagpovrayorg


Post a reply to this message


Attachments:
Download 'prova_06.txt' (1 KB) Download '67FR-RH.ies.txt' (27 KB)

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.